import request from '@/utils/request'

// 工单列表查询
export function getWorkOrderList(params) {
  return request({
    url: '/device/workOrder/list',
    method: 'get',
    params
  })
}

// 创建工单
export function addWorkOrder(data) {
  return request({
    url: '/device/workOrder/add',
    method: 'post',
    data
  })
}

// 修改工单
export function updateWorkOrder(data) {
  return request({
    url: '/device/workOrder/update',
    method: 'put',
    data
  })
}

// 工单详细信息
export function WorkOrderDetail(id) {
  return request({
    url: '/device/workOrder/'+id,
    method: 'get'
  })
}

// 删除工单
export function deleteWorkOrder(ids) {
  return request({
    url: '/device/workOrder/' + ids,
    method: 'delete',
  })
}



